﻿using System;
using System.Collections;
using System.Configuration;
using System.Data;
using System.Linq;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.HtmlControls;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Xml.Linq;
using LUStationery.Controller;
using LUStationery.Model;
using LUStationery.DAO;

public partial class CheckDepartmentInfomation : System.Web.UI.Page
{
    DepartmentControl departcont;
    UsersControl userscont;
    protected void Page_Load(object sender, EventArgs e)
    {

            string staffID = ((User)Session["user"]).StaffID.ToString();
            departcont = new DepartmentControl();
            Department depart = departcont.getDepartmentByUserID(staffID);
            lblDepartmentCode.Text = depart.DeptCode;
            lblDepartmentName.Text = depart.DeptName;
            lblCollectionPoint.Text = depart.CollectionPoint;
            lblRepresentative.Text = depart.Representative;
            userscont = new UsersControl();
            User user = userscont.getUserByUserName(depart.Representative);
            lblStaffID.Text = user.StaffID;

    }
}
